<!DOCTYPE html>
<html class="x-admin-sm">

  <head>
    <meta charset="UTF-8">
    <title>{$list.set.webtitle}</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width,user-scalable=yes, minimum-scale=0.4, initial-scale=0.8,target-densitydpi=low-dpi" />
    {load href="__XADMIN__/css/font.css" /}
    {load href="__XADMIN__/css/xadmin.css" /}
    {load href="__XADMIN__/js/jquery.min.js" /}
    {load href="__XADMIN__/lib/layui/layui.js" /}
    {load href="__XADMIN__/js/xadmin.js" /}
    {load href="__XADMIN__/js/cookie.js" /}
    <!-- 让IE8/9支持媒体查询，从而兼容栅格 -->
    <!--[if lt IE 9]>
      <script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
      <script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
    <!-- // 百度统计代码  -->
        <script>
          var _hmt = _hmt || [];
          (function() {
            var hm = document.createElement("script");
            hm.src = "https://hm.baidu.com/hm.js?6f65eecea5e089dae94d6b9cffec3623";
            var s = document.getElementsByTagName("script")[0];
            s.parentNode.insertBefore(hm, s);
          })();
        </script>
    {block name="jscss"}{/block}
  </head>
  <body>
    <div class="x-body">
    	{block name="form"}{/block}
    </div>
    <script>
      // config的设置是全局的
        layui.config({
            base: "__XADMIN__/js/" //假设这是你存放拓展模块的根目录
        });

      // layui.use(['form','mytable'], function(){
      //   var form = layui.form
      //       mytable = layui.mytable;
      //   // 监听复选框
      //   form.on('checkbox', function(data){
      //     checkall = $(data.elem).attr('checkall');
      //     parentId = $(data.elem).parents("div").attr('id');
      //     if(checkall=='p'){
      //       mytable.checkboxAll(parentId,data.elem.checked);
      //     }else if(checkall=='c'){
      //       mytable.checkboxParentList(parentId);
      //     }
      //   });

      //   //监听提交
      //   form.on('submit(mysubmit)', function(data){
      //     var downloadData={
      //       url:"{$list.set.url}",  //下载地址
      //       data:data.field, //要发送的数据
      //       method:"{$list.set.formpost}"
      //     }
      //     DownLoadFile(downloadData);
      //     return false;
      //   });


        /*===================下载文件
           * options:{
           * url:'',  //下载地址
           * data:{name:value}, //要发送的数据
           * method:'post'
           * }
           */
      //   function DownLoadFile(options) {
      //       var config = $.extend(true, { method: 'post' }, options);
      //       var $iframe = $('<iframe id="down-file-iframe" />');
      //       var $form = $('<form target="down-file-iframe" method="' + config.method + '" />');
      //       $form.attr('action', config.url);
      //       for (var key in config.data) {
      //           $form.append('<input type="hidden" name="' + key + '" value="' + config.data[key] + '" />');
      //       }
      //       $iframe.append($form);
      //       $(document.body).append($iframe);
      //       $form[0].submit();
      //       $iframe.remove();
      //   }
      // });
  </script>
  {block name="myjs"}{/block}
  </body>
</html>
